package cn.gok.dor.manager.controller;

import cn.gok.dor.manager.controller.dto.StudentQueryDTO;
import cn.gok.dor.manager.controller.vo.StudentListVO;
import cn.gok.dor.manager.service.IStudentService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**

 @Controller 将当前类标记为控制器类
 @ResponseBody  表示当前类中所有方法返回的结果为json数据

 @RestController  =  @Controller + @ResponseBody
 */
@RestController
@RequestMapping("/sys/student")
public class StudentController {

    @Resource
    private IStudentService studentService;

    /**
     {
        code :  200
        msg:    "操作成功"
        data:  学生集合
     }
     * 学生列表信息查看
     * @param queryParam
     * @return
     */
    @RequestMapping("/list")
    public StudentListVO getStudents(StudentQueryDTO queryParam){
       return studentService.getStudents(queryParam);
    }
}
